<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>Untitled Document</title>
</head>

<body style=" font-family:Arial, Helvetica, sans-serif;">
<h1>Customer Inquery Feedback Panel</h1>
<form action="" method="post">
<table width="900" border="1" cellspacing="0" cellpadding="10" style="font-size:12px;">
  <tr>
    <th scope="col">NO</th>
    <th scope="col">Shop</th>
    <th scope="col">Products</th>
    <th scope="col">Date</th>
    <th scope="col">Type</th>

    <th scope="col" style="width:200px;">Choose Feedback</th>
    <th scope="col">Comment AU<br />
      ( Input Barcode if Already Shipped)</th>
    <th scope="col">Au<br />
      Feedback
      <br />
      Date</th>
    <th scope="col" style="width:200px;">FeedBack China</th>
        <th scope="col">Comment China<br />
        (如果已发出 请放条码) <br /></th>
    <th scope="col">China<br />
      Feedback
      <br />
      Date</th>
    <th scope="col">Status</th>

    </tr>
  <?php 
  foreach($this->oldList as $k => $v ){

	  ?>
  <tr>
    <td><?php echo $k + 1;?></td>
    <td><?php echo $v['shop_head']?></td>
    <td><?php echo $v['content_inq']?></td>
    <td><?php echo $v['date_inq']?></td>
    <td><?php switch($v['qtype']){
		case(1):{echo "Inquery"; break;}
		case(2):{echo "Price Review"; break;}
		case(3):{echo "Bulk Faulty"; break;}
		}?></td>

    <td valign="top"><div style="width:200px;"> &nbsp;</div>
    	<select name="feedback_au[<?php echo $v['id_inq']?>]">
        <option value="" >--Please Select--</option>
        	<optgroup label="Update In 7 Days">
    	  <option value="1" <?php echo  ($v['feedback_au']== 1 )?'selected="selected"':'';?> >Sourcing Now</option>
          <option value="21" <?php echo ($v['feedback_au']== 21)?'selected="selected"':'';?> >Ken's Decision</option>
          <option value="31" <?php echo ($v['feedback_au']== 31)?'selected="selected"':'';?> >Similar Requirement</option>
          <option value="41" <?php echo ($v['feedback_au']== 41)?'selected="selected"':'';?> >Wait Another 7 Days</option>
    	</optgroup>
        <optgroup label="It is Updated">
        <option value="4"  <?php echo ($v['feedback_au']== 4)?' selected="selected"':'';?>  >Already Sent / In Stock</option>
        <option value="9"  <?php echo ($v['feedback_au']== 9)?' selected="selected"':'';?> >Will Not Get</option>
        </optgroup>
       <optgroup label="Other Options">
       <option value="7"  <?php echo ($v['feedback_au']== 7)?' selected="selected"':'';?>  >Requirement Not Clear</option>
       <option value="99" <?php echo ($v['feedback_au']== 99)?' selected="selected"':'';?>  >Cancel / It is an error</option>
       </optgroup> 
        
        </select>
       <input type="hidden" name="org_choice[<?php echo $v['id_inq']?>]" id="org_choice_<?php echo $v['id_inq']?>" value="<?php echo $v['feedback_au'];?>" />    <br /></td>
    <td><label for="cmt_au"></label>
      <textarea name="cmt_au[<?php echo $v['id_inq']?>]" id="cmt_au" cols="30" rows="5"><?php echo $v['comment_au']?></textarea></td>
    <td align="center"><?php echo ($v['feedback_date_au'] !='')?$v['feedback_date_au']:'<span style="color:#999;">N/A</span';?></td>
    <td valign="top"><div style="width:200px;"> &nbsp;</div>
      <input type="radio" name="feedback_cn[<?php echo $v['id_inq']?>]" id="radio7" value="11" disabled="disabled"  <?php echo ($v['feedback_cn']== 11)?'checked = "checked"':'';?> />
      产品可以拿到<br />
      <input type="radio" name="feedback_cn[<?php echo $v['id_inq']?>]" id="radio8" value="13" disabled="disabled" <?php echo ($v['feedback_cn']== 13)?'checked = "checked"':'';?> />
      无此产品/无类似产品<br />
      <input type="radio" name="feedback_cn[<?php echo $v['id_inq']?>]" id="radio9" value="15" disabled="disabled" <?php echo ($v['feedback_cn']== 15)?'checked = "checked"':'';?> />
      需要订做<br />
      <input type="radio" name="feedback_cn[<?php echo $v['id_inq']?>]" id="radio10" value="17" disabled="disabled" <?php echo ($v['feedback_cn']== 17)?'checked = "checked"':'';?> />
      已经从中国发出出<br />
      <input type="radio" name="feedback_cn[<?php echo $v['id_inq']?>]" id="radio12" value="2" disabled="disabled" <?php echo ($v['feedback_cn']== 17)?'checked = "checked"':'';?> />
将会在14天内发出</td>
      <td><textarea name="cmt_cn[<?php echo $v['id_inq']?>]" id="cmt_cn" cols="30" rows="5" readonly="readonly" ><?php echo $v['comment_cn'] ?></textarea>      <label for="eta_au"></label></td>
    <td align="center"><?php echo ($v['feedback_cn_date'] !='')?$v['feedback_cn_date']:'<span style="color:#999;">N/A</span';?></td>
     <td align="center">
     <?php
     	  $status = "Open";
		  if($v['feedback_au']== 7 || $v['feedback_au']== 9  || $v['feedback_au']== 4 ||  $v['feedback_au']== 99   ){
			  $status = "Complete";
			  }
		  echo $status;
	 ?>
    </tr>
  <?php }?>
 <?php 
 	
  foreach($this->cwList as $k => $v ){
	  ?>
  <tr>
    <td><?php echo $k + 1;?></td>
    <td><?php echo $v['shop_head']?></td>
    <td><?php echo $v['content_inq']?></td>
    <td><?php echo $v['date_inq']?></td>
    <td><?php switch($v['qtype']){
		case(1):{echo "Inquery"; break;}
		case(2):{echo "Price Review"; break;}
		case(3):{echo "Bulk Faulty"; break;}
		}?></td>

  <td valign="top"><div style="width:200px;"> &nbsp;</div>      <select name="feedback_au[<?php echo $v['id_inq']?>]">
 <option value="" >--Please Select--</option>
        	<optgroup label="Update In 7 Days">
    	  <option value="1" <?php echo  ($v['feedback_au']== 1 )?'selected="selected"':'';?> >Sourcing Now</option>
          <option value="21" <?php echo ($v['feedback_au']== 21)?'selected="selected"':'';?> >Ken's Decision</option>
          <option value="31" <?php echo ($v['feedback_au']== 31)?'selected="selected"':'';?> >Similar Requirement</option>
          <option value="41" <?php echo ($v['feedback_au']== 41)?'selected="selected"':'';?> >Wait Another 7 Days</option>
    	</optgroup>
        <optgroup label="It is Updated">
        <option value="4"  <?php echo ($v['feedback_au']== 4)?' selected="selected"':'';?>  >Already Sent / In Stock</option>
        <option value="9"  <?php echo ($v['feedback_au']== 9)?' selected="selected"':'';?> >Will Not Get</option>
        </optgroup>
       <optgroup label="Other Options">
       <option value="7"  <?php echo ($v['feedback_au']== 7)?' selected="selected"':'';?>  >Requirement Not Clear</option>
       <option value="99" <?php echo ($v['feedback_au']== 99)?' selected="selected"':'';?>  >Cancel / It is an error</option>
       </optgroup> 
    </select>    
    <input type="hidden" name="org_choice[<?php echo $v['id_inq']?>]" id="org_choice_<?php echo $v['id_inq']?>" value="<?php echo $v['feedback_au'];?>" /><br /></td>
    <td><label for="cmt_au"></label>
      <textarea name="cmt_au[<?php echo $v['id_inq']?>]" id="cmt_au" cols="30" rows="5"><?php echo $v['comment_au']?></textarea></td>
    <td align="center"><?php echo ($v['feedback_date_au'] !='')?$v['feedback_date_au']:'<span style="color:#999;">N/A</span';?></td>
    <td valign="top"><div style="width:200px;"> &nbsp;</div>
      <input type="radio" name="feedback_cn[<?php echo $v['id_inq']?>]" id="radio7" value="11" disabled="disabled"  <?php echo ($v['feedback_cn']== 11)?'checked = "checked"':'';?> />
      产品可以拿到<br />
      <input type="radio" name="feedback_cn[<?php echo $v['id_inq']?>]" id="radio8" value="13" disabled="disabled" <?php echo ($v['feedback_cn']== 13)?'checked = "checked"':'';?> />
      无此产品/无类似产品<br />
      <input type="radio" name="feedback_cn[<?php echo $v['id_inq']?>]" id="radio9" value="15" disabled="disabled" <?php echo ($v['feedback_cn']== 15)?'checked = "checked"':'';?> />
      需要订做<br />
      <input type="radio" name="feedback_cn[<?php echo $v['id_inq']?>]" id="radio10" value="17" disabled="disabled" <?php echo ($v['feedback_cn']== 17)?'checked = "checked"':'';?> />
      已经从中国发出<br />
      <input type="radio" name="feedback_cn[<?php echo $v['id_inq']?>]" id="radio" value="2" disabled="disabled" <?php echo ($v['feedback_cn']== 17)?'checked = "checked"':'';?> />
将会在14天内发出</td>
      <td><textarea name="cmt_cn[<?php echo $v['id_inq']?>]" id="cmt_cn" cols="30" rows="5" readonly="readonly" ><?php echo $v['comment_cn'] ?></textarea>      <label for="eta_au"></label></td>
    <td align="center"><?php echo ($v['feedback_cn_date'] !='')?$v['feedback_cn_date']:'<span style="color:#999;">N/A</span';?></td>
    
      <td align="center">
         <?php
     	  $status = "Open";
		  if($v['feedback_au']== 7 || $v['feedback_au']== 9  || $v['feedback_au']== 4 ||  $v['feedback_au']== 99   ){
			  $status = "Complete";
			  }
		
		 echo $status;	  
	 ?>
      </td>
    </tr>
  <?php }?>  
</table><br />

<input name="btn_sub_nh" type="submit" id="btn_sub_nh" />
</form>
<h1>
  Result</h1>
<h1>Click To Check History Here </h1>
<h3>&nbsp;</h3>
</body>
</html>
